package main

import (
	"bufio"
	"fmt"
	"os"
)

func dup() {
	counts := make(map[string]int)
	scan := bufio.NewScanner(os.Stdin)
	for scan.Scan() {
		counts[scan.Text()]++
	}
	for k, v := range counts {
		if v > 1 {
			fmt.Printf("%s: \t%d\n", k, v)
		}
	}
}
func main() {
	dup()
}
